package com.jd.org.mapper;

import com.jd.org.domain.Department;
import com.jd.org.query.DepartmentQuery;

import java.util.List;

public interface DepartmentMapper {
    /**
     * 查全部
     * @return
     */
    List<Department> findAll();

    /**
     * 查一条
     * @param id
     * @return
     */
    Department findOne(Long id);

    /**
     * 添加
     * @param department
     */
    void add(Department department);

    /**
     * 删除
     * @param id
     */
    void dalete(Long id);

    /**
     * 修改
     * @param department
     */
    void update(Department department);

    /**
     * 查询数据总条数
     * @return
     */
    Long queryCount();

    /**
     * 分页查询
     * @param departmentQuery
     * @return
     */
    List<Department> queryData(DepartmentQuery departmentQuery);

}
